#include <windows.h>
#include <stdio.h>
#include <tchar.h>

//extern "C" __declspec(dllimport) int Add(int nLeft, int nRight);
#include "./../DLLOne/DllOneHead.h" 
#pragma comment(lib, "./../Debug/DllOne.lib")

#include "./../DLLTwo/DLLTwoHead.h" 
#pragma comment(lib, "./../Debug/DLLTwo.lib")

#include "./../DLLThree/DLLThreeHead.h" 
#pragma comment(lib, "./../Debug/DLLThree.lib")

int main()
{
	// Test DLLOne
	{
		int nLeft, nRight;
		_tprintf(_T("\nDLLOne Test:\nPlease input two value for calculate(nLeft + nRight):  "));
		_tscanf_s(_T("%d %d"), &nLeft, &nRight);
		_tprintf(_T("Dll function calculate: %d + %d = %d(%d)\n"), nLeft, nRight, DLLOne_Result, DLLOne_Sum(nLeft, nRight));
	}

	// Test DLLTwo
	{
		int nLeft, nRight;
		_tprintf(_T("\nDLLTwo Test:\nPlease input two value for calculate(nLeft + nRight):  "));
		_tscanf_s(_T("%d %d"), &nLeft, &nRight);
		_tprintf(_T("Dll function calculate: %d + %d = %d(%d)\n"), nLeft, nRight, DLLTwo_Result, DLLTwo_Sum(nLeft, nRight));
	}

	// Test DLLThree
	{
		extern int __declspec(dllimport) DLLThree_Result;
		int nLeft, nRight;
		_tprintf(_T("\nDLLThree Test:\nPlease input two value for calculate(nLeft + nRight):  "));
		_tscanf_s(_T("%d %d"), &nLeft, &nRight);
		_tprintf(_T("Dll function calculate: %d + %d = %d(%d)\n"), nLeft, nRight, DLLThree_Result, DLLThree_Sum(nLeft, nRight));
	}
	
	system("pause");
	return 0;
}